package com.jy.rhin.domain.notification.topic.entity;

import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * @author WeiQ
 * @date 2022/6/28 9:50
 * 主题预存查询的过滤条件
 */
@Data
@NoArgsConstructor
public class TopicQueryFilterVO {

    public TopicQueryFilterVO(String filterName, String filterExp, String targetPath, String sourcePath, String filterType, String filterCode) {
        this.filterName = filterName;
        this.filterExp = filterExp;
        this.targetPath = targetPath;
        this.sourcePath = sourcePath;
        this.filterType = EnumFilterType.valueOf(filterType);
        this.filterCode = filterCode;
    }

    /**
     * 过滤条件名称
     */
    private String filterName;
    /**
     * 过滤条件表达式
     */
    private String filterExp;
    /**
     * 过滤条件JSON对象jsonPath
     */
    private String targetPath;
    /**
     * 过滤条件字段webService对象路径
     */
    private String sourcePath;
    /**
     * 比较表达式 LT:<  LE:<=   EQ:=  GE:>=  GT:>
     */
    private String compareExp;

    /**
     * 值域类型
     */
    private EnumFilterType filterType;
    /**
     * 值域code
     */
    private String filterCode;
}
